<!-- 使用defineProps defineEmits 实现v-model父子组件通信 -->
<template>
  <div>
    <h1>我是VModell父组件</h1>
    <div>isShow :{{ isShow }}</div>
    <div>text:{{ text }}</div>
    <div><button @click="isShow = !isShow">开关</button></div>
    <hr>
    <vModelVue v-model:textVal.isTx="text" v-model="isShow">
    </vModelVue>
  </div>
</template>
<script setup lang='ts'>
import { ref } from 'vue'
import vModelVue from './VModellll.vue';
const isShow = ref<boolean>(true)
const text = ref<string>('liu') 
</script>
<style scoped lang="scss"></style>